# -*- coding: utf-8 -*-#
#-------------------------------------------------------------------------------
# 建立者:        潘炎珍  
# Name:         demo12
# Description:
# Author:       98745
# Date:         2019/3/4
#-------------------------------------------------------------------------------

class F:
    def __init__(self):
        self.a=0
        self.b=1
    def __next__(self):
        result=self.a
        self.a,self.b=self.b,self.a+self.b
        return result
    def __iter__(self):
        return self
f=F()
for fs in f:
    print(fs,end=' ')
    if fs>500:
        break;

class R:
    def __init__(self):
        self.n=1
    def __next__(self):
        r='*'*(2*self.n-1)
        self.n+=1
        return r
    def __iter__(self):
        return self
r=R()
for e in r:
    if len(e)>21:
        break;
    print(e)